//
//  MYRequesTool.h
//  MiaoYin
//
//  Created by DarkWorld on 2020/1/4.
//  Copyright © 2020 thy. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "DWHTTPManager.h"

typedef NS_ENUM(NSUInteger, MYrequestType) {
    MYrequestType_Get = 0,
    MYrequestType_Post,
    MYrequestType_Put,
};
NS_ASSUME_NONNULL_BEGIN

/// 秒音请求类封装
@interface MYRequesTool : NSObject




/// 请求结果处理
/// @param result <#result description#>
+ (BOOL)requestReslutDelWith:(NSDictionary *)result;

/// 封装综合请求 不支持直播模块
/// @param urlString 后缀地址
/// @param requestType 请求方式
/// @param MYServiceModuleType 请求模块
/// @param params 请求参数
/// @param successHandle 成功回调
/// @param failureHandle 失败回调
+ (void)requestUrl:(NSString *)urlString
       requestType:(MYrequestType)requestType
MYServiceModuleType:(MYServiceModuleType)MYServiceModuleType
            params:(NSDictionary *)params
     successHandle:(void(^)(id response))successHandle
     failureHandle:(void(^)(NSError *error))failureHandle;
/// 封装综合请求 目前仅阿里短视频使用  jsonbody传值
/// @param urlString 后缀地址
/// @param requestType 请求方式
/// @param MYServiceModuleType 请求模块
/// @param params 请求参数
/// @param successHandle 成功回调
/// @param failureHandle 失败回调
+ (void)requestBodyUrl:(NSString *)urlString
       requestType:(MYrequestType)requestType
MYServiceModuleType:(MYServiceModuleType)MYServiceModuleType
            params:(NSString *)params
     successHandle:(void(^)(id response))successHandle
     failureHandle:(void(^)(NSError *error))failureHandle;


+ (void)checkVersion;
@end

NS_ASSUME_NONNULL_END
